#ifndef __HASHMAP_H__
#define __HASHMAP_H__

#include<stdio.h>
#include<stdlib.h>

#define N 100

typedef char* C;
typedef int V;
typedef struct entry_s
{
	C key;
	V val;
	struct entry_s* next;
}Entry;

typedef struct hashmap_s
{
	Entry* table[N];
}HashMap;

//API
HashMap* create_hashmap();
void destroy_hashmap(HashMap* map);
V hashmap_get(HashMap* map, C key);
void hashmap_add(HashMap* map, C key);
V hashmap_put(HashMap* map, C key, V val);
V hashmap_delete(HashMap* map, C key);
int hash(C key);

#endif